﻿using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

namespace JavaScript
{
    /// <summary>
    /// JavaScript 的摘要说明
    /// JavaScript弹出窗口封装类
    /// </summary>
    public class JSDialog
    {
        public JSDialog()
        {
            //
            // TODO: 在此处添加构造函数逻辑
            //
        }
        public static void Alert(System.Web.UI.Page page, string msg)
        {
            System.Text.StringBuilder Builder = new System.Text.StringBuilder();
            Builder.Append("<script language='javascript'>");
            Builder.AppendFormat("alert('{0}');", msg);
            Builder.Append("</script>");
            page.ClientScript.RegisterStartupScript(page.GetType(), "Attention", Builder.ToString());
        }
    }
}
